<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>商城导航栏</title>
    <link rel="stylesheet" href="./css/bootstrap.css">
    <link rel="stylesheet" href="./css/style.css">
    <script src="./js/jquery-3.7.1.js"></script>
    <script src="./js/bootstrap.min.js"></script>
    <style>
        .header{
            /* 在页面上方 */
            position: fixed;
            width: 100%;
            top: 0;
            z-index: 999;
        }
        body {
            display: flex;
            flex-direction: column;
            position: relative;
            min-height: 100vh;
        }
        
        .footer {
            background-color: #f8f9fa;
            padding: 20px 0;
            text-align: center;
            position: absolute;
            bottom: 0;
            width: 100%;
        }

        .footer p {
            margin: 0;
            font-family: '微软雅黑', sans-serif;
            font-size: 16px;
            color: #28a745;
            animation: fadeIn 2s ease-in-out;
        }

        .container,
        form {
            animation: fadeIn 2s ease-in-out;
        }

        @keyframes fadeIn {
            from {
                opacity: 0;
            }

            to {
                opacity: 1;
            }
        }

        label {
            margin-top: 10px;
            font-size: 12px;
            color: #28a74654;
        }

        label.xrequired::after {
            content: '* ';
            font-size: 12px;
            color: rgba(255, 0, 0, 0.562);
        }

        h2 {
            text-align: center;
            margin-top: 20px;
            font-size: 30px;
            color: #28a745;
            font-weight: bold;

        }

        /* 表单 */
        form {
            animation: fadeIn 2s ease-in-out;
            max-width: 500px;
            margin: 50px auto;
            padding: 20px;
            background-color: #fff;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
            border-radius: 8px;
            margin-bottom: 100px;
        }

        .form-group {
            margin-bottom: 15px;
        }

        .form-group label {
            display: block;
            margin-bottom: 5px;
            font-weight: bold;
        }

        .form-control {
            width: 100%;
            padding: 8px;
            font-size: 16px;
            border: 1px solid #ced4da;
            border-radius: 4px;
            box-sizing: border-box;
            transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
        }

        .form-control:focus {
            border-color: #80bdff;
            outline: 0;
            box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
        }

        .btn-primary {
            margin: 20px;
            width: 100px;
            padding: 5px 10px;
            font-size: 16px;
            background-color: #28a7468a;
            border: none;
            border-radius: 4px;
            color: #fff;
            cursor: pointer;
            transition: background-color 0.3s ease;
        }

        .btnBox {
            text-align: center;
        }

        .btn-primary:hover {
            background-color: #28a746;
        }

        @media (max-width: 768px) {

            .container,
            form {
                padding: 15px;
            }

            h2 {
                font-size: 20px;
            }

            .btn-primary {
                font-size: 14px;
            }
        }
    </style>
</head>

<body>
    <!-- header -->
    <header class="header">
        <div class="container">
            <nav class="navbar navbar-default" role="navigation">
                <div class="collapse navbar-collapse" id="navbar-collapse-1">
                    <ul class="nav navbar-nav">
                        <li><a href="/index">首页</a></li>
                        <li class="dropdown">
                            <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
                                商品分类
                                <span class="caret"></span></a>
                            <ul class="dropdown-menu">
                                <li><a href="#">Action</a></li>
                                <li><a href="#">Another action</a></li>
                                <li><a href="#">Something else here</a></li>
                                <li role="separator" class="divider"></li>
                                <li><a href="#">Separated link</a></li>
                                <li role="separator" class="divider"></li>
                                <li><a href="#">One more separated link</a></li>
                            </ul>
                        </li>
                        <li><a href="#">热销</a></li>
                        <li><a href="#">新品</a></li>
                        <li><a href="./user_register.html" class="active">注册</a></li>
                        <li><a href="#">登录</a></li>
                    </ul>  
                </div>
            </nav>
            <div class="header-info">
                <div class="header-right search-box">
                    <a href="javascript:;"><span class="glyphicon glyphicon-search" aria-hidden="true"></span></a>
                    <div class="search">
                        <form class="navbar-form navbar-left">
                            <div class="form-group">
                                <input type="text" class="form-control" placeholder="搜寻你想要的内容">
                                <button type="submit" class="btn btn-default">确定</button>
                            </div>
                        </form>
                    </div>
                </div>
                <div class="header-right cart">
                    <a href="/goods_cart.jsp">
                        <span class="glyphicon glyphicon-shopping-cart" aria-hidden="true">
                            <span class="card_num"></span>
                        </span>
                    </a>
                </div>
                <div class="clearfix"></div>
            </div>
            <div class="clearfix"></div>
        </div>
    </header>
    <section>
        <h2>注册新用户</h2>
        <form action="/user_register" method="post">
            <div class="form-group">
                <!-- 包含用户名，邮箱，密码，收货人，联系电话，收货地址 -->
                <label for="username" class="xrequired">用户名</label>
                <input type="text" class="form-control" id="username" name="username" placeholder="请输入用户名"></input>

                <label for="email" class="xrequired">邮箱</label>
                <input type="email" class="form-control" id="email" name="email" placeholder="请输入邮箱"></input>

                <label for="password" class="xrequired">密码</label>
                <input type="password" class="form-control" id="password" name="password" placeholder="请输入密码"></input>

                <label for="confirm_password">确认密码</label>
                <input type="password" class="form-control" id="confirm_password" name="confirm_password"
                    placeholder="请再次输入密码"></input>

                <!-- 收货人 -->
                <label for="receiver">收货人</label>
                <input type="text" class="form-control" id="receiver" name="receiver" placeholder="请输入收货人"></input>
                <label for="phone">联系电话</label>
                <input type="text" class="form-control" id="phone" name="phone" placeholder="请输入联系电话"></input>
                <label for="address">收货地址</label>
                <input type="text" class="form-control" id="address" name="address" placeholder="请输入收货地址"></input>
                <div class="btnBox">
                    <button type="submit" class="btn btn-primary">提交</button>
                </div>
            </div>
        </form>
    </section>
    <footer class="footer">
        <div>
            <p>
                陈煜-软工华为2206-202212390606
            </p>
        </div>
    </footer>
</body>

</html>